import { Component } from '@angular/core';
import { RouterOutlet } from '@angular/router';
import {PageList} from './page-list/page-list';
import {SearchBar} from './search-bar/search-bar';
import {Wikipedia} from './wikipedia';


@Component({
  selector: 'app-root',
  imports: [RouterOutlet, PageList, SearchBar],
  templateUrl: './app.html',
  styleUrl: './app.css'
})
export class App {
  constructor(private wikipedia:Wikipedia) {

  }
  onTerm(term:string){
    const results = this.wikipedia.search(term);
    console.log(results);
  }

}


